package com.newland.zxy.controller;

import com.newland.zxy.bean.User;
import com.newland.zxy.dao.UserDao;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author zhangxuyuan
 * @version 1.0
 * @date 2021/1/14
 */
@RestController
public class TestController {

    @Autowired
    private UserDao userDao;

    @GetMapping("/userList")
    public List<User> getUserList()
    {
        return userDao.getAllUsers();
    }
}
